export const USER_LIST = 'USER_LIST'
export const SET_USERLIST = 'SET_USERLIST'
export const USRE_SUCCESS = 'USRE_SUCCESS'
export const USRE_ERROR = 'USRE_ERROR'

export interface UsersAction {
    type: typeof USER_LIST,
    payload: SearchUserParams
}

export interface SearchUserParams {
    name?: string,
    current: number
}

export const getUserList = (payload: SearchUserParams): UsersAction => {
    return ({ 
        type: USER_LIST,
        payload
    })
}